package IMIC.NGUYENVANTINH.ARRAY.EXCERCISE.EX02;

public class Models {
	public double Average(double[] myarr) {
		double sum = 0;
		for (int i = 0; i < myarr.length; i++) {
			sum += myarr[i];
		}
		System.out.println("Mang vua nhap theo kieu double");
		double avg = sum/myarr.length;
		return avg;

	}
	public double Average(int[] myarr) {
		double sum = 0;
		for (int i = 0; i < myarr.length; i++) {
			sum += myarr[i];
		}
		System.out.println("Mang vua nhap theo kieu int");
		double avg = sum/myarr.length;
		return avg;

	}

}
